import enum,re

class UserStatusEnum(enum.Enum):
    """用户状态"""
    NORMAL = "1"
    LIMIT = "2"

class PermissionEnum(enum.Enum):
    """角色权限"""
    READ = "1"
    PUBLISH = "2"
    COMMENT = "3"

# class FriendStatusEnum(enum.Enum):
#     """好友状态"""
#     NO = "0"
#     YES = "1"
#     DEFAULT = "2"


# 用户名正则表达式
USERNAME_PATTERN = r'^[a-zA-Z0-9_]+$'

# @用户
AT_USER_PATTERN = r'@(?P<User>[a-zA-Z0-9]+)'

# 话题
TOPIC_PATTERN = r'#(?P<Topic>[a-zA-Z0-9_\-\u4e00-\u9fa5]+)#'